import request from '@/utils/request'

export function add(data) {
  return request({
    url: 'buss-contract/bigscream/add',
    method: 'post',
    data
  })
}

export function edit(data) {
  return request({
    url: 'buss-contract/bigscream/edit',
    method: 'post',
    data
  })
}

export function listPage(data) {
  return request({
    url: 'buss-contract/bigscream/listPage',
    method: 'post',
    data
  })
}

export function del(data) {
  return request({
    url: 'buss-contract/bigscream/del',
    method: 'post',
    data
  })
}

export function getOne(id) {
  return request.get('buss-contract/bigscream/getOne?id='+id)
}

export function getAllProjectForScream(data) {
  return request({
    url: 'buss-contract/project/getAllProjectForBigScream',
    method: 'post',
    data
  })
}

export function getAllProjectWithUserScope(data) {
  return request({
    url: 'buss-contract/project/getAllProjectWithUserScope',
    method: 'post',
    data
  })
}

export function getProjectData(projectId,mapDataId='') {
  return request.get('buss-contract/bigscream/getProjectData?projectId='+projectId+'&mapDataId='+mapDataId)
}

export function projectworkinfoListPage(data) {
  return request({
    url: 'buss-contract/projectworkinfo/listPage',
    method: 'post',
    data
  })
}

export function saveProjectInfo(data) {
  return request({
    url: 'buss-contract/bigscream/saveProjectInfo',
    method: 'post',
    data
  })
}

export function getProjectInfo() {
  return request.get('buss-contract/bigscream/getProjectInfo')
}
export function getPorjectInfoAll() {
  return request.get('buss-contract/project/getPorjectInfoAll')
}

export function getPorjectInfoById(data) {
  return request.get('buss-contract/project/getPorjectInfoById?projectId='+data)
}

export function getUserJscPermission(data) {
  return request.post('buss-contract/project/getUserJscPermission',data)
}
//获取项目办驾驶舱 投资数据
export  function getInvestmentSituation(data) {
  return request.post('buss-contract/project/getInvestmentSituation',data)
}
//获取项目办驾驶舱 线路经纬度
export  function getCircuitDiagram(id) {
  return request.get('buss-contract/project/getCircuitDiagram?projectId='+id)
}
//获取项目办驾驶舱效果图
export  function getXgtFileId(id) {
  return request.get('buss-contract/project/getXgtFileId?projectId='+id)
}
//获取项目办驾驶舱效果图
export  function getVideoFileId(id) {
  return request.get('buss-contract/project/getVideoFileId?projectId='+id)
}
//获取项目办下部折线图
export  function getStatistics(data) {
  return request.post('buss-contract/investmentmonthreport/getStatistics',data)
}
// 获取投资分析累计投资
export function getAccumulatedInvestmentCompletion(data) {
  return request.post('buss-contract/bigscream/accumulatedInvestmentCompletion', data);
}
// 获取投资分析年度投资
export function getaccumulatedInvestmentYear(data) {
  return request.post('buss-contract/bigscream/getaccumulatedInvestmentYear', data);
}
// 获取投资分析月度投资
export function getaccumulatedInvestmentMonth(data) {
  return request.post('buss-contract/bigscream/getaccumulatedInvestmentMonth', data);
}
// 获取投资分析资金到位情况
export function getFundingStatus(data) {
  return request.post('buss-contract/bigscream/getFundingStatus', data);
}
// 获取投资分析资金到位情况-by project
export function getFundingStatusProject(data) {
  return request.post('buss-contract/bigscream/getFundingStatusProject', data);
}
// 获取投资分析投资完成情况-by project
export function getInvestmentCompletion(data) {
  return request.post('buss-contract/bigscream/getInvestmentCompletion', data);
}

export function getProjectOne(id) {
  return request.post('buss-contract/project/getOne?id='+id);
}

export function getOnePicDataByType(data) {
  return request.post('buss/mapdata/getOnePicDataByType',data);
}
export function getVideoMap() {
  return request.post('buss/video/getVideoMap', {});
}
export function analysisCAD(data) {
  return request.post('buss/planlibmanage/analysisCAD',data);
}
export default {
  getOne,
  add,
  edit,
  listPage,
  del,
  getAllProjectForScream,
  getProjectData,
  projectworkinfoListPage,
  saveProjectInfo,
  getProjectInfo,
  getPorjectInfoAll,
  getPorjectInfoById,
  getUserJscPermission,
  getInvestmentSituation,
  getCircuitDiagram,
  getXgtFileId,
  getVideoFileId,
  getStatistics,
  getAllProjectWithUserScope,
  getProjectOne,
  analysisCAD,
  getOnePicDataByType,
}
